Repository navigation
feat(share): share the interactive owner’s native engine (#688) - #1237
Conversation
|
@codex review |
|
@codex security review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
Security findingsAdvisory findings (1)ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8371aa3413
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
🛡️ Codex Security ReviewSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
|
@codex review |
|
@codex security review |
|
Codex Review: Didn't find any major issues. You're on a roll. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
There was a problem hiding this comment.
🛡️ Codex Security Review
Here are some automated security review suggestions for this pull request.
Reviewed commit: dc6fb8617b
ℹ️ About Codex security reviews in GitHub
This is an experimental Codex feature. Security reviews are triggered when:
- You comment "@codex security review"
- A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review
Once complete, Codex will leave suggestions, or a comment if no findings are found.
| bind: Option<IpAddr>, | ||
| ) -> Result<Prepared, OxaError> { | ||
| let config = Config { | ||
| binding: bind.map_or(Binding::Tailnet, Binding::Explicit), |
There was a problem hiding this comment.
🛡️ Codex Security Review
Security: Restrict interactive sharing to protected binds
When the share feature is built and an owner runs --share-model ... --share-bind 0.0.0.0 (or uses a LAN IP), this line maps every parsed IP directly to Binding::Explicit; the listener then serves plaintext HTTP and accepts the 64-hex guest bearer in Authorization. A LAN/on-path attacker observing one guest request can replay that share key for model requests and consume its quota while the session runs. Default Tailnet binding and bearer auth do not protect a bearer exposed outside encrypted Tailscale; guest routes exclude tools/cloud, so this is P2. Reject non-loopback/non-Tailscale explicit binds (or require TLS).
SECURITY.md reference: SECURITY.md:L9-L13
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Confirmed for the standalone branch head. #1235 landed the common restriction on main at 6ecc77a before this review. A clean merge preview of dc6fb86 with main 0095e87 yields tree 82bbc085b7c8097508e1c8109a13d647e75deedf. Its oxc-gateway/src/share/native.rs is byte-identical to the landed #1235 file, and the interactive Prepared::serve calls that exact adapter. The adapter rejects unspecified and multicast addresses and checks offers against the Tailscale addresses before binding outside loopback. The composed tree retains native_cleartext_listener_refuses_wildcard_and_unverified_interfaces from #1235, which passed in merge-group run https://github.com/oxstack/ox-llm/actions/runs/44200298827. This is a source preview of the composition. The merge group still needs to qualify it. No main merge was made into the branch.
Feature F · Rust product · T3
Refs #688 and #1214. Follow-up to #1216. The bind restriction from #1235 landed at
6ecc77a3.An interactive owner can opt in to sharing selected native local models. The local owner route and the guest listener use the same native engine instance, preserving the existing owner-first lease queue. The listener closes and joins its worker when the owner session ends. Agent-launched and noninteractive sessions cannot activate sharing.
Reuses the native gateway, its key and tailnet checks, and the foreground listener setup for both entry points. The option is absent from normal startup unless explicitly selected.
Verification
8371aa3413da4734253ecf1f4c017041b68881dc. The merge of landed feat(share): serve selected native local models over LAN (#688) #1216 resolved genuine text conflicts. A zero-context comparison verified that the six-file owner delta was preserved.A read-only merge rehearsal against landed
6ecc77a3preserved all six files’ added and deleted lines and kept the bind restriction byte-for-byte.Owner stream timeout
Sharing now uses the effective session timeout through the same native engine settings helper as an ordinary session. Native launch settings still come from user settings. Foreground share serve continues to use its user-only settings load.
Hosted lane 44203241365 reproduced the regression on x86_64 and ARM64 at
f836e2431b23fb1174be4e8033904426f276b01d. On each, the new oxa-cli test was the sole failure (1,281 passed), observing 1,700 ms instead of the configured 2,400 ms. Fix headdc6fb8617b57c764591e74dd7bf1d5769d035a75passed the hosted lane 44204435750 on x86_64 and ARM64, including the selected oxa-cli tests and the share-feature CLI controls. Required checks 44204444747 also passed on this head, including both mandatory-bwrap partitions and the aggregate inventory gate.Removes: the inline agent-marker check, duplicate native local-engine construction, and inline foreground listener setup — the same checks and setup now run through the shared agent predicate, native settings helper, and prepared listener used by both sharing entry points. The Tailscale socket literal moved into their shared constant. No source files were deleted.